package com.asdf.entities;

/** This class implements the airport.
 * @author so4i2014
 *
 */
public class Airport
{
	
	/** Airport id.
	 * 
	 */
	private String id   = null;
	/** Airport name.
	 * 
	 */
	private String name = null;
	/** Country the airport is located in.
	 * 
	 */
	private String country = null;
	/** The price of the service in the airport.
	 * 
	 */
	private double rate;
	/** The license file for this airport.
	 * 
	 */
	private String licenseFile;
	
	
	
	/** Create an airport with the following details:
	 * @param id - airport id
	 * @param country - airport country
	 * @param licenseFile - license file for the airport
	 * @param name - airport name
	 * @param rate - price of the service in the airport per minute
	 */
	public Airport( String id, String country, String licenseFile, String name, double rate)
	{
		this.id = id;
		this.country = country;
		this.licenseFile = licenseFile;
		this.name = name;
		this.rate = rate;
	}
	
	public String getId( )
	{
		return id;
	}

	public void setId( String id)
	{
		this.id = id;
	}

	public final String getName( )
	{
		return name;
	}
	public final void setName( String name)
	{
		this.name = name;
	}
	public final String getCountry( )
	{
		return country;
	}
	public final void setCountry( String country)
	{
		this.country = country;
	}
	public final double getRate( )
	{
		return rate;
	}
	public final void setRate( double rate)
	{
		this.rate = rate;
	}
	public final String getLicenseFile( )
	{
		return licenseFile;
	}
	public final void setLicenseFile( String licenseFile)
	{
		this.licenseFile = licenseFile;
	}
	
	@Override
	public boolean equals( Object obj)
	{
		return ((Airport)obj).getId( ).equalsIgnoreCase( id);
	}
	
}
